<?php echo $header; ?>
<div id="content">
    <div class="breadcrumb">
        <?php echo "qq客服"; ?>
    </div>
    <div class="box">
        <div class="heading">
            <h1><img src="view/image/user.png" alt="" /> <?php echo "添加qq客服"; ?></h1>
            <div class="buttons"><a onclick="$('#form').submit();" class="button"><?php echo $_['button_save']; ?></a>
                <a href="<?php echo UA('tool/livechat'); ?>" class="button"><?php echo $_['button_cancel']; ?></a></div>
        </div>
        <div class="content">
            <form action="<?php echo $action; ?>" method="post" enctype="multipart/form-data" id="form">
                <table class="form">
                    <tbody id="row-skin" >
                    <tr>
                        <td><?php echo $_['column_name']; ?></td>
                        <td><input type="text" name="qqName" value="<?php echo $qqName; ?>" />
                           </td>
                    </tr>
                    <tr>
                        <td><span class="required">*</span><?php echo 'qq号'; ?></td>
                        <td><input type="text" name="qqNumber" value="<?php echo $qqNumber; ?>"
                                   onkeyup="(this.v=function(){this.value=this.value.replace(/[^0-9-]+/,'');}).call(this)" onblur="this.v();"/>
                        </td>
                    </tr>
                       <tr>
                        <td><?php echo $_['column_status']; ?></td>
                        <td>
                            <select name="qqStatus">
                                <option value="1"<?php echo ($qqStatus==1)? ' selected' : ''; ?>><?php echo $_['text_enabled']; ?></option>
                                <option value="0"<?php echo ($qqStatus==0)? ' selected' : ''; ?>><?php echo $_['text_disabled']; ?></option>
                            </select>
                        </td>
                    </tr>
                </table>
            </form>
        </div>
    </div>
</div>
<script type="text/javascript"><!--
    function load_default_skin(type) {
        if (type == 'CODE') {
            $('#row-skin').css('display', 'none');
        }
        else {
            $('#row-skin').css('display', '');
        }
        html = $('#skin-' + type).html();
        $('#skin').html(html);
    }

    function preview(idx) {
        var sel = document.getElementById('skin');
        var image = sel.options[sel.selectedIndex].text;
        if (image == '') {
            $('#thumb').attr('src', '<?php echo $no_image; ?>'); $('#image').attr('value', '');
        }
        else {
            image = "<?php echo HTTP_IMAGE?>/kf/" + image;
            $('#thumb').attr('src', image); $('#image').attr('value', '');
        }
    }
    //--></script>
<?php echo $footer; ?>